package com.waypolice.manager.controller;

import java.util.Iterator;
import java.util.LinkedHashMap;
import java.util.List;
import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.waypolice.manager.service.UserService;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import net.sf.json.JSONArray;

import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

import com.waypolice.manager.service.MainMenuService;
/**
 * 获取左侧导航菜单栏
 * @author zhangxiaoyang
 *
 */
@Controller
@Api(value = "左侧导航菜单栏", description = "获取左侧导航菜单栏")
@RequestMapping(value="/pcwindow")
public class MainMenuAction {

	private static final Logger LOGGER = LoggerFactory.getLogger(MainMenuAction.class);

	@Autowired
	private MainMenuService mainmenuservice;

	/**
	 * 获取菜单列表
	 * @param request
	 * @param response
	 * @return
	 */
	/*@ApiOperation(value = "获取菜单列表")
	@RequestMapping(value="/getMainMenu",method = RequestMethod.POST)
	@ResponseBody
	public String getMainMenu(HttpServletRequest request,
							  HttpServletResponse response){
		List<Map<String, Object>> mainMenu = mainmenuservice.getMainMenu();
		Map<String,Object> map = new LinkedHashMap<String, Object>();
		map.put("menus", mainMenu);
		JSONArray menulist=JSONArray.fromObject(map);
		String str = menulist.toString();
		return str;
	}*/


}
